import * as types from './mutations_types';

module.exports = {
    //设置展示用户的数据
    set_users_data: ({
        commit
    }, obj) => {
        commit(types.SET_USERS_DATA, obj);
    },
    //删除某个用户的数据
    delete_table_user: ({
        commit
    }, obj) => {
        commit(types.DELETE_TABLE_USER, obj);
    },
    //更新用户数据
    update_user_data: ({
        commit
    }, obj) => {
        console.log(obj);
        commit(types.UPDATE_USER_DATA, obj);
    },
    //清空用户筛查数据
    clean_select_data: ({
        commit
    }) => {
        commit(types.CLEAN_SELECT_DATA);
    },
    //设置用户筛查数据
    set_select_options: ({
        commit
    }, obj) => {
        commit(types.SET_SELECT_OPTIONS, obj);
    },
    //设置页码
    set_page_index: ({
        commit
    }, obj) => {
        commit(types.SET_PAGE_INDEX, obj);
    }
}